<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2021/3/26
  Time: 16:43
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" isELIgnored="false" %>
<%@taglib prefix="s" uri="/struts-tags" %>
<html>
<head>
    <title>控制标签</title>
</head>
<body>
    <%--<s:if>、<s:elseif>、<s:else>、<s:iterator>标签--%>
    <table border="1px" cellpadding="1">
        <s:iterator var="name" value="{'AAA','BBB','CCC','DDD','EEE','FFF'}" status="st">
            <s:if test="#st.odd">
                <tr style="background-color:lavender">
                    <td><s:property value="#st.index"/></td>
                    <td><s:property value="name"/></td>
                </tr>
            </s:if>
            <s:else>
                <tr style="background-color: burlywood">
                    <td><s:property value="#st.index"/></td>
                    <td><s:property value="name"/></td>
                </tr>
            </s:else>
        </s:iterator>
    </table>
    <br/><br/>


    输出字符串：
    <s:property value="this is a string"/><br/>
    输出默认值：
    <s:property value="" default="this is default value"/><br/>
    忽略HTML代码：
    <s:property value="<h1>html ignore</h1>" escape="true"/><br/>
    不忽略HTML代码：
    <s:property value="<h1>html not ignore</h1>" escape="false"/><br/>
    <br/>

    <s:a namespace="/" action="login_">www.baidu.com</s:a>
    <br/>

    <s:debug/>
    <br/>

    包含的页面
    <s:include value="suc.jsp">
        <s:param name="success" value="'传值AAA'"/>
    </s:include>
</body>
</html>
